  class Window_EquipSkill < Window_Selectable
    def initialize(actor)
      super(0, 0, 320, 480)
      @actor = actor
      @column_max = 1
      self.index = 0
      refresh
    end
    def refresh
      if self.contents != nil
        self.contents.dispose
        self.contents = nil
      end
      # If item count is not 0, make a bit map and draw all items
      @item_max = @actor.equip_skills.size
      if @item_max > 0
        self.contents = Bitmap.new(self.width - 10, row_max * 64)
        for i in 0...@item_max
          draw_item(i)
        end
      end
    end
    def draw_item(index)
      rect = Rect.new(4, 32 * index, self.contents.width - 8, 32)
      ite = @actor.equip_skills[index]
      if ite == nil
        return
      end
      self.contents.fill_rect(rect, Color.new(0, 0, 0, 0))
      self.contents.draw_text(rect, ite.name + '   [LV ' + ite.level.to_s + ']')
    end
    def item
      return @actor.equip_skills[self.index]
    end
    #--------------------------------------------------------------------------
    # * Help Text Update
    #--------------------------------------------------------------------------
    def update_help
      ite = self.item
      @help_window.set_text(ite == nil ? "" : ite.description[ite.level])
    end
  end
